Domain change

Update(s) on this.topic

Our main Internet domain is changing this year. dacbarbos.info is set to expire on 2024-05-02 and no further renewal is planned. dacbarbos.eu is the new official domain for our brand. Going forward, only two domains shall remain active: dacbarbos.eu and wot.ro. We added a shared status page for both, accesible via their respective status subdomain.

NOTE: this is a duplicate post. Original is here.

Note to Self: ABCs of the Internet

These are some key concepts one must learn on its life-long learning journey.

As personal cherry-picks, these concepts exemplify the intricacies outlined in the ever-growing collection of RFCs (the number is set to surpass 10 000 by next year). Understanding these ABCs will smooth the path to one’s next practical application.

A geek’s notes on Windows Desktop

This post is primarily meant as a #NoteToSelf for future reference. Whether with the occasion of a distant HW refresh of my PC or simply during a fresh SW (re)install/(re)build, I shall reuse this knowledge gathered over the last 2-3 years of sporadic Windows 10/11 desktop use. Looking back in time, when Windows 95 brought a new look and feel to the Windows desktop, things were a lot simpler. Fast forward to 2023, it’s a totally different story in terms of apps/tools one should know or care about. My hope is that other fellow geeks and/or friends might find these notes useful.

C:\Users\geek>
#################################################################
# msstore: CrystalDiskMark, DevToys, HashMe, Mastodon, Messenger,
# msstore: Move Mouse, Rufus, Sysinternals Suite, tldraw, Wintoys
# msstore: Windows File Recovery [aka.ms/winfrhelp], AV1, HEIF...
# sysinternals: few manifests for winget, all/most on scoop repo
# themes: Dark Skies by Tracy Hymas, Light and Dark by Nick Boyer
#################################################################

## Install PyEnv, Python, wsl2, Ansible, pre-commit, s3cmd
Set-ExecutionPolicy RemoteSigned -Scope CurrentUser # PowerShell
Invoke-WebRequest -UseBasicParsing -Uri "https://raw.githubusercontent.com/pyenv-win/pyenv-win/master/pyenv-win/install-pyenv-win.ps1" -OutFile "./install-pyenv-win.ps1"; &"./install-pyenv-win.ps1"
# open https://github.com/pyenv-win/pyenv-win/blob/master/docs/installation.md#add-system-settings

pyenv install 3.7.9 # powercli
pyenv install 3.9.9 # newish
pyenv update # refresh
pyenv install 3.11.5 # newer
pyenv global 3.11.5 # set
#pyenv local --unset
#pyenv shell --unset

wsl --install
wsl --version
wsl --update
wsl --list --online
wsl --install -d ubuntu
#################################################################
# open https://learn.microsoft.com/en-us/windows/wsl/wsl-config
# cat /etc/wsl.conf
[automount]
enabled=true

[boot]
systemd=true

[interop]
enabled=false
appendWindowsPath=false
#################################################################
# open http://tiny.cc/ornbvz && https://bit.ly/3FTT2qU
# run next commands on wsl (due to above reasons)
python3 -m pip install --user --upgrade pip
python3 -m pip install --user --upgrade ansible
python3 -m pip install --user --upgrade argcomplete
# open https://docs.python.org/3/library/site.html
python3 -m site # beware of the paths
pyenv which ansible # NO ansible.exe (!)
ansible --version # you may exit wsl
python3 -m pip install pre-commit
pre-commit --version
python3 -m pip install s3cmd
s3cmd --configure

### Useful winget commands
winget install --id Adobe.Acrobat.Reader.64-bit # must have || DC@msstore
winget install --id Amazon.AWSCLI # awscli, optional, devops
winget install --id Amazon.SessionManagerPlugin # awscli, optional, devops
winget install --id Amazon.SAM-CLI # awscli, optional, devops
winget install --id Anaconda.Miniconda3 # optional, devops
winget install --id angryziber.AngryIPScanner # must have, netintel
winget install --id argoproj.argocd # GitOps for k8s, optional
winget install --id Apache.DirectoryStudio # LDAP client, optional
winget install --id Audacity.Audacity # audio editor, should have || scoop
winget install --id Azul.Zulu.8.JDK # (compat) || scoop bucket add java
winget install --id BelledonneCommunications.Linphone # VoIP client, optional
winget install --id BlenderFoundation.Blender # optional || msstore || scoop
winget install --id Canva.Canva # optional || msstore
winget install --id chrisant996.Clink # spice up cmd shell, yes && clink autorun -h
winget install --id ChristianHohnstadt.xca # optional, pki, x509
winget install --id dbeaver.dbeaver # SQL client, optional, devops
# NB: more to choose from at www.nerdfonts.com/font-downloads || scoop bucket add nerd-fonts
winget install --id DEVCOM.JetBrainsMonoNerdFont # jb-mono-NF, should have one
winget install --id direnv.direnv # dir auto-env, optional
winget install --id Docker.DockerCLI # good to have (podman-desktop/issues/4696)
winget install --id Docker.DockerCompose # good to have, devops
winget install --id dotPDNLLC.paintdotnet # must have || GIMP.GIMP
winget install --id FarManager.FarManager # must have, mc4win
winget install --id Git.Git # must have, git-scm
winget install --id GitHub.cli # await scoop (fq,jq) # should have, gh
## gh extension install korosuke613/gh-user-stars ^-^ # if deps were met
## gh extension install joaom00/gh-b # branch mgmt (gh b)
winget install --id GitHub.GitLFS # large file storage
winget install --id GnuPG.Gpg4win # must have, yes
winget install --id GoLang.Go # should have || goenv
## go install github.com/sibprogrammer/xq@latest # xq/issues/30, should have
winget install --id Google.Chrome # must have, browser
winget install --id Google.CloudSDK # optional, devops
winget install --id Google.Terraformer # optional, IaC
winget install --id Graphviz.Graphviz # graph visualization || scoop
winget install --id Gyan.FFmpeg # video(s)++ || scoop
winget install --id HandBrake.HandBrake # optional || scoop
winget install --id Hashicorp.Terraform # IaC || tfenv ; pip3 install checkov
winget install --id HTTPie.HTTPie # optional, devops
winget search terraform # find more IaC tools
winget install --id Inkscape.Inkscape # should have || msstore
winget install --id JGraph.Draw # draw.io, diagrams.net
winget install --id karakun.OpenWebStart # should have (for Java apps)
winget install --id Keybase.Keybase # crypto.im
winget install --id KeePassXCTeam.KeePassXC # must have
winget install --id lsd-rs.lsd # ls -deluxe
winget install --id MarekJasinski.FreeCommanderXE # should have
winget install --id Meld.Meld # should have, windiff || scoop
winget search "Microsoft.Azure" # find more CLIs
winget install --id Microsoft.AzureCLI # mscli, optional, devops
winget install --id Microsoft.Bicep # msIaC, optional, devops
winget install --id Microsoft.DotNet.Runtime.8 # should have, latest/LTS
winget install --id Microsoft.DotNet.SDK.8 # should have, latest/LTS
winget install --id Microsoft.Git # msfork, optional
winget install --id Microsoft.NuGet # pkgmgr, should have
winget install --id Microsoft.OneDrive # must have, cloud drive
winget install --id Microsoft.OpenJDK.21 # should have, latest
winget install --id Microsoft.PowerShell # should have, latest
winget install --id Microsoft.SBOMTool # optional, devops || scoop
winget install --id Microsoft.Skype # optional, VoIP || msstore
winget install --id Microsoft.VisualStudioCode # obvious, should have
winget install --id Microsoft.VCRedist.2015+.x86 # 32-bit, should have
winget install --id Microsoft.VCRedist.2015+.x64 # 64-bit, should have
winget install --id Microsoft.WinDbg # optional, should have
winget install --id Microsoft.WindowsTerminal # must have || msstore
winget install --id Microsoft.WingetCreate # optional, devops
winget install --id MongoDB.MongoDBAtlasCLI # optional, devops
winget install --id MoritzBunkus.MKVToolNix # optional || msstore || scoop
winget install --id Mozilla.Firefox # must have, browser
winget install --id Mozilla.SOPS # secrets, should have
winget install --id MSYS2.MSYS2 # update-core && pacman -Suu
winget install --id Ninja-build.Ninja # optional, devops
winget install --id Notepad++.Notepad++ # must have, yes
winget install --id Nushell.Nushell # smart shell, optional
winget install --id OpenWhisperSystems.Signal # crypto.im, should have
winget install --id PuTTY.PuTTY # must have || NoMoreFood.PuTTY-CAC
winget install --id PortSwigger.BurpSuite.Community # optional, netintel
winget install --id qBittorrent.qBittorrent # optional, forget uTorrent
winget install --id RaspberryPiFoundation.RaspberryPiImager # optional, random
winget install --id RedHat.Podman # containers, should have
winget install --id RedHat.Podman-Desktop # containers, should have
winget install --id Rclone.Rclone # optional, maybe
winget install --id rhysd.actionlint # optional, fyi || scoop
winget install --id SaltStack.SaltMinion # optional, fyi
winget install --id Starship.Starship # prompt++, fya || scoop
winget install --id StephanDilly.gitui # optional, fya || scoop
winget install --id StrawberryPerl.StrawberryPerl # should have || plenv
winget install --id Telegram.TelegramDesktop # crypto.im, should have || msstore
winget install --id TheDocumentFoundation.LibreOffice # must have || scoop
winget install --id Twilio.Authy # should have, desktop 2fa/mfa
winget install --id WhatsApp.WhatsApp # crypto.im, should have || msstore
winget install --id Winamp.Winamp # optional, audio player
winget install --id WinSCP.WinSCP # must have || msstore
winget install --id YS-L.csvlens # cli csv viewer, should have
winget ls --scope user |sort /M 8192 /O winget_%username%.txt # what do we have so far? winget-cli/issues/1155
#winget upgrade -uhr [--accept-package-agreements --accept-source-agreements] # obvious, all

### Install Scoop # more info at scoop.sh
# NB: below setting is wanted by "scoop checkup" so better set it in advance...
reg add HKLM\SYSTEM\CurrentControlSet\Control\FileSystem /v LongPathsEnabled /t REG_DWORD /d 1 /f
Set-ExecutionPolicy RemoteSigned -Scope CurrentUser # PowerShell
irm get.scoop.sh | iex # official install method
## Install Volta # more info at volta.sh
scoop update # obvious, self
scoop install volta # action/task
#scoop update -a # obvious, all
## Install Node # more info at nodejs.org
volta install node # latest LTS is default
volta install npm # standard node pkg mgr
volta install pnpm # more info at pnpm.io
volta install yarn # more info at yarnpkg.com
volta install deno # more info at deno.com
volta install did-cli # optional, decentralized IDs
volta install jsonld # optional, good to have (dev)
volta install jsonld-cli # optional, good to have (dev)
volta install @pnp/cli-microsoft365 # optional, good to have (cli)
volta list >volta_%username%.txt # what do we have so far?
## Install extra tools # yes, please do so :-)
scoop bucket add extras # age,pasteboard,sfsu are in this.repo
scoop bucket list # expected repos present?: main,extras
scoop status # is everything else ok?
scoop install 7zip # file arc/comp/decompress
scoop install age # file enc/decrypt utility
scoop install ant # optional, java, devops
scoop install base64 # must have utility (rfc4648)
scoop install dufs # optional, file server
scoop install fq # optional, jq for binnaries
scoop install fzf # fuzzy finder used by gh user-stars ext
scoop install glab # gitlab's official cli client
#scoop install graphviz # graph visualization || winget
scoop install helm helmfile # k8s chart(s) tools
scoop install hostctl # local hosts file mgmt
scoop install ipinfo-cli # network intelligence
scoop install jenv # should have, JRE/JDK mgr
# NB: prefer scoop over winget for jq aka jqlang.jq (keep it simple)
scoop install jc jo jp jq jx # must have j[?] tools
scoop install jqp # optional, gojq with a TUI
scoop install kind # good to have (Podman-Desktop|Kind)
scoop install kubectl # k8s systems mgmt cli
scoop install krew # kubectl plugin manager
scoop install maven # should have, java, devops
scoop install micro # console text editor (nano4win)
scoop install minikube # minimal k8s system || kind bit.ly/3rrQjBm
scoop install minisign # file crypto signer, good to have (dev)
scoop install mkcert # internal CA/certs, good to have (dev)
scoop install osv-scanner # scan for oss sec vulns
scoop install q-dns # network intelligence
scoop install sfsu # stupid fast scoop utils
scoop install tflint tfsec # terraform extras
scoop install ugrep # must have grep4win
scoop install win-acme # should have, ACMEv2 client
scoop install yq # jq for YAML
scoop list >scoop_%username%.txt # what do we have so far?

# .NET
dotnet tool install --global wix
wix --version # https://wixtoolset.org
# alternative: scoop info dark

# QEMU & Friends
https://www.qemu.org
https://libguestfs.org
https://libvirt.org
https://qemu.weilnetz.de/w64/
winget install --id SoftwareFreedomConservancy.QEMU || scoop
#https://github.com/cloud-hypervisor/edk2/releases/latest > CLOUDHV.fd

# QEMU-GUI
https://github.com/Tech-FZ/EmuGUI
https://github.com/ispras/qemu-gui
#open https://bit.ly/3N3sqY6
#scoop install qtemu # extras

# Raw vs Qcow2 + conversions
https://www.vinchin.com/en/blog/raw-vs-qcow2.html
https://docs.openstack.org/image-guide/convert-images.html

# VirtIO-Win
https://virtio-fs.gitlab.io
https://wiki.qemu.org/Features/VirtIORNG
https://wiki.qemu.org/Features/VirtioSCSI
https://access.redhat.com/solutions/1758693
https://github.com/virtio-win/virtio-win-pkg-scripts
https://fedorapeople.org/groups/virt/virtio-win/direct-downloads/

# Windows guest drivers
https://www.linux-kvm.org/page/WindowsGuestDrivers

# Windows spice-webdavd + vdagent
https://www.spice-space.org/download/windows/spice-webdavd/
https://www.spice-space.org/download/windows/vdagent/

# Win11 as guest (tips & tricks)
https://kevinlocke.name/bits/2021/12/10/windows-11-guest-virtio-libvirt/
https://blogs.oracle.com/virtualization/post/install-microsoft-windows-11-on-virtualbox

# VMware PowerCLI
PS C:\Users\geek> Install-Module -Name VMware.PowerCLI -Scope CurrentUser

NuGet provider is required to continue
PowerShellGet requires NuGet provider version '2.8.5.201' or newer to interact with NuGet-based repositories. The NuGet
provider must be available in 'C:\Program Files\PackageManagement\ProviderAssemblies' or
'C:\Users\geek\AppData\Local\PackageManagement\ProviderAssemblies'. You can also install the NuGet provider by
running 'Install-PackageProvider -Name NuGet -MinimumVersion 2.8.5.201 -Force'. Do you want PowerShellGet to install
and import the NuGet provider now?
[Y] Yes [N] No [S] Suspend [?] Help (default is "Y"): N
Install-Module : NuGet provider is required to interact with NuGet-based repositories. Please ensure that '2.8.5.201'
or newer version of NuGet provider is installed.

# Install/Update Mandy (hugo alternative)
iex ((New-Object System.Net.WebClient).DownloadString(’https://angeldollface.art/mandys-house/installers/win_64.ps1’))

# device portal
https://learn.microsoft.com/en-us/windows/uwp/debug-test-perf/device-portal-ssl

# shall you need/want Ruby
https://github.com/nak1114/rbenv-win#installation

# [Ad-hoc] network services (tftp, dhcp, dns)
https://github.com/PJO2/tftpd64/
https://sourceforge.net/projects/tftp-server/
https://sourceforge.net/projects/dhcpserver/
https://sourceforge.net/projects/dhcp-dns-server/

# My favfonts:
https://www.programmingfonts.org/#anonymous-pro
https://www.programmingfonts.org/#code-new-roman
https://www.programmingfonts.org/#gnu-freefont
https://www.programmingfonts.org/#go-mono
https://www.programmingfonts.org/#monoid
https://www.programmingfonts.org/#redhat

# Misc
curl cht.sh
curl ip.me
curl ip.wtf
curl wttr.in

The Three Musketeers (in AAA)

I still like to use the triple A acronym due to its simplicity (!). Not easy to forget. In the context of this post I will state that AAA = Authentication and Authorization. For the sake of accuracy I will also point you to the exact meaning as explained by Techopedia.

Nowadays with the cloud and as-a-service (aaS) paradigm, web2.0, web3.0 applications, APIs, services and/or microservices there comes the three musketeers (in AAA). Everybody heard of them, heck, some (if not all) webdevs are in a close friendship relation with these three musketeers.

Without further due, let’s introduce them: OpenID, OAuth and SAML. Well, yes we did hear about them but why are so important to worth writing this article? Even though they fight for the same cause, each one is doing it in its very own way and a lot of confusion happens. Here I share for myself and others some good resources to explore and help lift the confusion:

If you mention the names of our three musketeers on YouTube, you will be rewarded with some nice videos like this.

The busy JavaScript developer’s guide to ECMAScript 6

A series of four articles were recently published on IBM’s developerWorks portal by Ted Neward. I use this article as a rich bookmarks container pointing to the above.

At the bottom of each page (article) you’ll find a link to download that content as a PDF.

Blue-Ray and Linux

Yet another sad story, maybe one of the reasons I prefer macOS (formerly OS X) as my primary OS. This post is more like a note to self. Hopefully things will change for the better one day. Today the “options” are quite limited:

  1. MakeMKV
  2. AACS Keys

Even though this is a mini article, I do anticipate some hits due to normal interest on the topic. Of course there is a 3rd option: just buy an external full featured BD player device.

Kernel and WiFi

Not always a success story. Since this is a work in progress kind of thing (I currently struggle with it), I will be very brief. I hit some issues (instability) on a brand new laptop using Debian derivate distro (both Ubuntu and Mint). I had a bit of comfort seeing that I’m not alone. The exact error and similar symptoms are to be found here. It seems to be either firmware or adapter settings related. I noticed that on Intel’s page there is a newer version of iwlwifi-3160-ucode-25.30.14.0.tgz versus iwlwifi-3160-ucode-16.242414.0.tgz on Linux Kernel’s page. I will follow this lead for the moment. If I feel that I need to spend too much time with it, I’m going to take more radical measures (install something else).

Update (5 min later):

It seems that version I downloaded from Intel’s page loads without problem.

dacbarbos@dacairone:~$ journalctl -b | grep firmware
iun 18 11:57:34 dacairone kernel: iwlwifi 0000:03:00.0: loaded firmware version 25.30.14.0 op_mode iwlmvm
iun 18 11:57:36 dacairone NetworkManager[757]: <info> [1466240256.3999] manager[0x10721a0]: monitoring kernel firmware directory ‘/lib/firmware’.
iun 18 11:57:55 dacairone org.freedesktop.fwupd[741]: (fwupd:1955): Fu-WARNING **: Failed to coldplug: UEFI firmware updating not supported
dacbarbos@dacairone:~$

Dropbox updates

I’ve been quite ignorant about it like a true “modern” cloud services consumer. Well, this weekend I managed to catch up a little bit with them. It looks like there’s both good and bad news. The good news is: our data is now hosted on Dropbox’s own storage infrastructure (out of AWS where it was originally hosted). Yes, I missed that announcement. For me as a data storage professional, the details of their Magic Pocket architecture are quite interesting from a technical point of view. I’ve been reading before about somewhat similar approach (implemented by other provider/vendor). Now the bad news is about their ideas for future. They call it “Project Infinite” and you may read all the glory details here. Why I call it bad news? Simply because I share most of the views already expressed by other people on their page comments section. I’m already uncomfortable with Oracle’s VirtualBox kext. I don’t need more.

Off you go! A story of moving out my devtest VM

This article is intended for people who like to play with their laptops at home, taking advantage of the CPU‘s virtualization capabilities therefore firing up several VMs. I assume everybody know by now what a VM is. The story is more compelling to those using a laptop with an internal SSD drive which (due to higher cost) has usually less usable storage capacity as opposed to the old school HDD. I like to keep a Windows-based VM around to test random stuff from time to time or even use some specific tools which either don’t have yet a good Unix/Linux alternative or just because I’m too lazy. My Hypervisor of choice is Oracle’s VirtualBox due to its simplicity and user friendliness. My Windows 7 VM (more specifically the virtual disk used by it a.k.a. “W7_SystemDisk.vdi” file) has recently grown to 30 GiB which is a lot for my limited SSD capacity. Therefore, I decided that I must do something about it. My decision was grounded on the fact that I rarely use this VM (like once a week) and I have more important ones to build and run (i.e. try new Linux distribution releases). Given that my laptop has a built-in SD slot, I went and bought a Samsung micro SDXC card to use it as a new home for my afore-mentioned VM.

microSDXC_SamsungPro
Samsung Pro 64

Of course one can use a standard USB flash drive for the very same purpose. Next important choice I had to decide upon was of course: which file system to use? There is always a trade-off between usability (portability) and performance. As I knew that performance will drop much after moving my VM on this little thing, I quickly made up my mind: performance is my priority. Also since I recently found a nice, tiny utility for Windows which I wanted to test, I had the perfect opportunity to do so.

My VM system disk (C:) was looking like this:

System_Drive
Drive C: Properties

Here is what I did next:

Benchmark #1

– format the SDXC card using HFSPlus
– copied entire “TestVM_Folder” under root
– start VM from SDXC then ran the Parkdale

Parkdale_Default
Parkdale Default Settings

Windows 7 performance result

VDI_HFSPlus_540x180
VirtualBox VDI (NTFS-inside) on top of HFSPlus

Benchmark #2

– format the SDXC card using NTFS
– copied entire “TestVM_Folder” under root
– start VM from SDXC then ran the Parkdale

Windows 7 performance result

VDI_NTFS_540x180
VirtualBox VDI (NTFS-inside) on top of NTFS

Benchmark #3

– format the SDXC card using ExFAT
– copied entire “TestVM_Folder” under root
– start VM from SDXC then ran the Parkdale

Windows 7 performance result

VDI_exFAT_540x180
VirtualBox VDI (NTFS-inside) on top of ExFAT

Conclusion:

ExFAT is/was the best choice for me as my priority was performance.
One may go further and apply some well-known NTFS performance hacks.